<?PHP
class UsersModel extends Model {
    // 定义自动验证
    protected $_validate    =   array(
	    array('username','require','用户名必须'),
        array('username','','用户名已存在',0,'unique',1),
		array('password','require','密码必须'),
		array('password','6,60','密码长度不能小于6位',1,'length'),
		array('repassword','password','确认密码不正确',0,'confirm'),
		
        );
    // 定义自动完成
  protected $_auto    =   array(
        array('password','md5',3,'function'),
        );
}
?>